package services

import (
	"permange/dao"
	"permange/models"
)

func Getposts() (error, []models.Posts) {
	postsData,err  := dao.Selectposts()
	return err, postsData
}
func Getposts_e(eposition string) ([]models.Employee,error) {
	employee, err:= dao.Selectposts_e(eposition)
	return employee,err
}
func Updateposts(posts models.Posts) error{
	err:= dao.Updateposts(posts)
	return err
}

func Addposts(posts models.Posts) error {
	err := dao.Addposts(posts)
	return err
}

func Delposts(id string) error {
	err := dao.Deleteposts(id)
	return err
}
